Package-level declarations

Experimental APIs, subject to change in future versions.

Types

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
interface Bound<out T : Comparable<@UnsafeVariance T>>

Represents a bound in a range.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
@Serializable(with = EmailAddressSerializer::class)
class EmailAddress

Represents an email address.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
class ExclusiveBound<out T : Comparable<@UnsafeVariance T>> : Bound<T>

Represents an exclusive bound in a range.

Link copied to clipboard
@DeprecatedSince(warningSince = KotoolsTypesVersion.V4_4_0)
annotation class ExperimentalCollectionApi

Marks declarations that are still experimental in the collection API.

Link copied to clipboard
@Since(version = KotoolsTypesVersion.V4_4_0)
annotation class ExperimentalKotoolsTypesApi

Marks declarations that are still experimental in the API.

Link copied to clipboard
@DeprecatedSince(warningSince = KotoolsTypesVersion.V4_4_0)
annotation class ExperimentalNumberApi

Marks declarations that are still experimental in the number API.

Link copied to clipboard
@DeprecatedSince(warningSince = KotoolsTypesVersion.V4_4_0)
annotation class ExperimentalRangeApi

Marks declarations that are still experimental in the range API.

Link copied to clipboard
@DeprecatedSince(warningSince = KotoolsTypesVersion.V4_4_0)
annotation class ExperimentalResultApi

Marks declarations that are still experimental in the result API.

Link copied to clipboard
@DeprecatedSince(warningSince = KotoolsTypesVersion.V4_4_0)
annotation class ExperimentalTextApi

Marks declarations that are still experimental in the text API.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
class InclusiveBound<out T : Comparable<@UnsafeVariance T>> : Bound<T>

Represents an inclusive bound in a range.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
class NotEmptyRange<out T : Comparable<@UnsafeVariance T>>

Represents a range of comparable values that contain at least one value.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
@Serializable(with = StrictlyPositiveDoubleSerializer::class)
class StrictlyPositiveDouble : Comparable<StrictlyPositiveDouble>

Represents a floating-point number of type Double that is greater than zero.

Functions

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
@JvmName(name = "create")
fun AnyInt(value: Int): AnyInt

Creates an instance of AnyInt with the specified value.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun <T : Comparable<T>> NotEmptyRange<T>.contains(value: T): Boolean

Returns true if this range contains the given value, or returns false otherwise.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
fun <T : Comparable<T>> notEmptyRangeOf(bounds: NotEmptyRange.BuilderScope<T>.() -> Pair<Bound<T>, Bound<T>>): NotEmptyRange<T>

Returns a not empty range with the given pair of bounds. The resulting range will start with the lowest value between the given bounds.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun Char.plus(other: NotBlankString): NotBlankString

Concatenates this character with the other string.

@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun NotBlankString.plus(other: Char): NotBlankString

Concatenates this string with the other character.

@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun NotBlankString.plus(other: String): NotBlankString
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun NotBlankString.plus(other: NotBlankString): NotBlankString

Concatenates this string with the other one.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
fun Number.toStrictlyPositiveDouble(): Result<StrictlyPositiveDouble>

Returns this number as an encapsulated StrictlyPositiveDouble, which may involve rounding or truncation, or returns an encapsulated IllegalArgumentException if this number is negative.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun AnyInt.unaryMinus(): AnyInt
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun NegativeInt.unaryMinus(): PositiveInt
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun NonZeroInt.unaryMinus(): NonZeroInt
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun PositiveInt.unaryMinus(): NegativeInt
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun StrictlyNegativeInt.unaryMinus(): StrictlyPositiveInt
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
operator fun StrictlyPositiveInt.unaryMinus(): StrictlyNegativeInt

Returns the negative of this integer number.

Properties

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
val NonZeroInt.Companion.negativeRange: NotEmptyRange<StrictlyNegativeInt>

The negative range of values a NonZeroInt can have.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
val NonZeroInt.Companion.positiveRange: NotEmptyRange<StrictlyPositiveInt>

The range of positive values a NonZeroInt can have.

Link copied to clipboard
@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
val NegativeInt.Companion.range: NotEmptyRange<NegativeInt>

The range of values a NegativeInt can have.

@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
val PositiveInt.Companion.range: NotEmptyRange<PositiveInt>

The range of values a PositiveInt can have.

@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
val StrictlyNegativeInt.Companion.range: NotEmptyRange<StrictlyNegativeInt>

The range of values a StrictlyNegativeInt can have.

@ExperimentalSince(version = KotoolsTypesVersion.V4_4_0)
val StrictlyPositiveInt.Companion.range: NotEmptyRange<StrictlyPositiveInt>

The range of values a StrictlyPositiveInt can have.